package com.crp.unitalinforbaseplat.app.sys.dao;

import com.crp.unitalinforbaseplat.app.sys.entity.UserRole;
import org.apache.ibatis.annotations.Mapper;
import org.jetbrains.annotations.Nullable;

import java.util.List;

@Mapper
public interface UserRoleMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(UserRole record);

    int insertSelective(UserRole record);

    UserRole selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(UserRole record);

    int updateByPrimaryKey(UserRole record);


    List<UserRole> selectByUserId(String userId);

    void deleteByUserId(@Nullable String userId);

    void deleteByRoleId(Long roleId);

    void insertBatch(List<UserRole> userRoles);
}